package inv.cal;


import inv.cal.logic.EventsInfo;
import inv.cal.logic.EventsInfo.EventType;

import java.util.ArrayList;
import java.util.List;
import java.util.Locale;

import javax.swing.JFrame;
import javax.swing.SwingUtilities;

/**
 * Hello world!
 *
 */
public class App 
{
	public static void main(String[] args) {
		SwingUtilities.invokeLater(new Runnable() {
			public void run() {
				List<EventsInfo> events	= new ArrayList<EventsInfo>();
				java.util.Calendar cal	= java.util.Calendar.getInstance();
				events.add(new EventsInfo(cal.getTime(), "test1", EventType.INFO));
				cal.add(java.util.Calendar.DAY_OF_MONTH, 1);
				events.add(new EventsInfo(cal.getTime(), "test2", EventType.WARN));
				cal.add(java.util.Calendar.DAY_OF_MONTH, 1);
				events.add(new EventsInfo(cal.getTime(), "test3", EventType.INFO));
				events.add(new EventsInfo(cal.getTime(), "test4", EventType.WARN));
				
				DatePickerDialog thisClass = CalendarFactory.createDatePicker(null, Locale.getDefault(), events);
				thisClass.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
				thisClass.setVisible(true);
			}
		});
	}
}
